home *** CD-ROM | disk | FTP | other *** search
- # The Grand Rapids Free Net Login.cmd
- #
- # Trumpet 2.0 login script
- # Modified Sept. 8, 1995
-
- # In the PPP Options selection under the File menu set the PAP
- # option and enter your login id and password.
-
- # Under the Dialler menu run the setup.cmd script. Enter the
- # phone number, leave the user id and password entries blank.
-
- # trace on
-
- #----------------------------------------------------------
- # read the phone number from the ini file
-
- if ! [load $number]
- display \n"No Phone Number - Run the Setup Script"\n
- abort
- end
-
- #----------------------------------------------------------
- # initialize variables
-
- %attempts = 50
- %count = 0
- %connect = 0
- %busy = 0
-
- #----------------------------------------------------------
- # initialize the modem
-
- display "Initializing Modem ..."\n
- output "ATZ"\n
- if ! [input 10 OK\n]
- display \n"Modem is not responding"\n
- abort
- end
-
- #----------------------------------------------------------
- # dial the phone number
-
- display "Dialing ..."\n
- repeat
- if %count = %attempts
- display \n"Too many dial attempts"\n
- abort
- end
- output "ATTD "$number\n
- %busy = [input 10 BUSY]
- if ! %busy
- %connect = [input 45 CONNECT]
- end
- %count = %count + 1
- until %connect
-
- #----------------------------------------------------------
- # give the modem time to connect
-
- wait 30 dcd
-
- #----------------------------------------------------------
- # End OF Script